package com.weipai.demo.controller;

import com.weipai.demo.service.CreditSettingService;
import com.weipai.demo.util.Response;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class CreditSettingController {
    @Autowired
    private CreditSettingService creditSettingService;


    @RequestMapping("/creditSetting/getSetting")
    public Response getSetting(){
        return creditSettingService.getAll();
    }

    @RequestMapping("/creditSetting/setSettingById")
    public Response setSetting(String creditSetting){
        return creditSettingService.setSetting(creditSetting);
    }
}
